#pragma once
#ifndef SQL_PARSER_H
#define SQL_PARSER_H
#include <vector>
#include <string>
#include <map>
#include <sstream>

typedef std::map<std::string, int> mapint;
enum SQL_TYPE
{
	I_SHOW,I_CREATE,I_DROP,I_INSERT,I_SELECT,
	I_show,I_create,I_drop,I_insert,I_select
};



class SQL_Parser
{
public:
	SQL_Parser();
	SQL_Parser(const char*);
	~SQL_Parser();

private:
	const char* m_sqlstr;
	SQL_TYPE m_type;


	std::vector<std::string> parse_res;
public:
	void set_sql(const char* sql);
	SQL_TYPE get_type();
	std::vector<std::string>* pasrse_sql();



};
#endif // !SQL_PARSER_H

